package com.flyco.modules.sms.entity;

import java.io.Serializable;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.flyco.common.aspect.annotation.Dict;
import lombok.Data;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import com.flyco.poi.excel.annotation.Excel;

/**
 * @Description: 抽奖明细
 * @Author: flyco
 * @Date:   2020-04-16
 * @Version: V1.0
 */
@Data
@TableName("sms_lottery_item")
public class SmsLotteryItem implements Serializable {
    private static final long serialVersionUID = 1L;

	/**id*/
	@TableId(type = IdType.AUTO)
	private Long id;
	/**抽奖活动id*/
	private Long lotteryId;
	/**是否删除*/
    @Excel(name = "是否删除", width = 15)
	@TableLogic
	private Integer delFlag;
	/**奖项名称*/
    @Excel(name = "奖项名称", width = 15)
	private String name;
	/**奖品图片*/
    @Excel(name = "奖品图片", width = 15)
	private String pic;
	/**权重*/
    @Excel(name = "权重", width = 15)
	private Integer weight;
	/**奖项数量*/
    @Excel(name = "奖项数量", width = 15)
	private Integer total;
	/**每用户可抽总数量*/
    @Excel(name = "每用户可抽总数量", width = 15)
	private Integer numOfMember;
	/**当前中奖数量*/
    @Excel(name = "当前中奖数量", width = 15)
	private Integer numberNow;
	/**奖品类型：coupon/product*/
    @Excel(name = "奖品类型：coupon/product", width = 15)
	@Dict(dicCode = "lottery_prize_type")
	private String prizeType;
	/**奖项开始时间:为空表示中奖当时的时间点*/
	@Excel(name = "奖项开始时间:为空表示中奖当时的时间点", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
	private java.util.Date prizeStartTime;
	/**奖项使用有效天数*/
    @Excel(name = "奖项使用有效天数", width = 15)
	private Integer prizeDays;
	/**奖品级别： 9高价值奖，2普级奖， 1没有中奖*/
    @Excel(name = "奖品级别： 9高价值奖，2普级奖， 1没有中奖", width = 15)
	private Integer level;
	/**用于抽奖页面展示时的编号*/
    @Excel(name = "用于抽奖页面展示时的编号", width = 15)
	private Integer viewIndex;
	/**奖品bean的主id， sms_coupon.id(if prize_type==coupon)*/
    @Excel(name = "奖品bean的主id， sms_coupon.id(if prize_type==coupon)", width = 15)
	private Integer prizeMainId;
	/**奖品编号 coupon_grant表的grant_uuid*/
	@Excel(name = "奖品编号 coupon_grant表的grant_uuid", width = 15)
    private String prizeMainCode;
	/**奖品bean的配置id， sms_coupon_gant.id(if prize_type==coupon)*/
    @Excel(name = "奖品bean的配置id， sms_coupon_gant.id(if prize_type==coupon)", width = 15)
	private Integer prizeSubId;
	/**奖品bean的其它配置*/
    @Excel(name = "奖品bean的其它配置", width = 15)
	private Object prizeConfig;
	/**中奖图片*/
    @Excel(name = "中奖图片", width = 15)
	private String winningTipsPic;
	/**中奖提示*/
    @Excel(name = "中奖提示", width = 15)
	private String winningTips;
	/**创建人*/
	private String createBy;
	/**创建时间*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
	private Date createTime;
	/**更新人*/
	private String updateBy;
	/**更新时间*/
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
	private Date updateTime;
}
